// This file was decompiled using SASCM.ini published by GTAG (http://gtag.gtagaming.com/opcode-database) on 14.6.2013
{$CLEO .CS}

//-------------MAIN---------------
thread 'FLIP' 

while true
    repeat
    wait 0
    until if Player.Defined(0)
    if Actor.Driving($PLAYER_ACTOR)
    then 
        if 0449:   actor $PLAYER_ACTOR in_a_car
        then
            0@ = Actor.CurrentCar($PLAYER_ACTOR)
            if not Car.Wrecked(0@)
            then
                if and
                    01F4:   car 0@ flipped
                    81F3:   not car 0@ in_air
                    84A7:   not actor $PLAYER_ACTOR driving_boat 
                then
                    //03E5: show_text_box 'CFL'
                    0407: store_coords_to 1@ 2@ 3@ from_car 0@ with_offset 0.0 0.0 1.0 
                    04D3: get_nearest_car_path_coords_from 1@ 2@ 3@ 2  4@ 5@ 6@ 
                    Car.PutAt(0@, 4@, 5@, 6@)
                    Camera.Restore_WithJumpCut
                end
            end
        enD
    enD
end